package com.netflexitysolutions.amazonws.ec2;

public class ReservedInstancesOffering {

	private String reservedInstancesOfferingId;
	
	private InstanceType instanceType;
	
	private String availabilityZone;
	
	private long duration;
	
	private double fixedPrice;
	
	private double usagePrice;
	
	private String productDescription;

	/**
	 * @return the reservedInstancesOfferingId
	 */
	public String getReservedInstancesOfferingId() {
		return reservedInstancesOfferingId;
	}

	/**
	 * @param reservedInstancesOfferingId the reservedInstancesOfferingId to set
	 */
	public void setReservedInstancesOfferingId(String reservedInstancesOfferingId) {
		this.reservedInstancesOfferingId = reservedInstancesOfferingId;
	}

	/**
	 * @return the instanceType
	 */
	public InstanceType getInstanceType() {
		return instanceType;
	}

	/**
	 * @param instanceType the instanceType to set
	 */
	public void setInstanceType(InstanceType instanceType) {
		this.instanceType = instanceType;
	}

	/**
	 * @return the availabilityZone
	 */
	public String getAvailabilityZone() {
		return availabilityZone;
	}

	/**
	 * @param availabilityZone the availabilityZone to set
	 */
	public void setAvailabilityZone(String availabilityZone) {
		this.availabilityZone = availabilityZone;
	}

	/**
	 * @return the duration
	 */
	public long getDuration() {
		return duration;
	}

	/**
	 * @param duration the duration to set
	 */
	public void setDuration(long duration) {
		this.duration = duration;
	}

	/**
	 * @return the fixedPrice
	 */
	public double getFixedPrice() {
		return fixedPrice;
	}

	/**
	 * @param fixedPrice the fixedPrice to set
	 */
	public void setFixedPrice(double fixedPrice) {
		this.fixedPrice = fixedPrice;
	}

	/**
	 * @return the usagePrice
	 */
	public double getUsagePrice() {
		return usagePrice;
	}

	/**
	 * @param usagePrice the usagePrice to set
	 */
	public void setUsagePrice(double usagePrice) {
		this.usagePrice = usagePrice;
	}

	/**
	 * @return the productDescription
	 */
	public String getProductDescription() {
		return productDescription;
	}

	/**
	 * @param productDescription the productDescription to set
	 */
	public void setProductDescription(String productDescription) {
		this.productDescription = productDescription;
	}

	/* (non-Javadoc)
	 * @see java.lang.Object#hashCode()
	 */
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime
				* result
				+ ((reservedInstancesOfferingId == null) ? 0
						: reservedInstancesOfferingId.hashCode());
		return result;
	}

	/* (non-Javadoc)
	 * @see java.lang.Object#equals(java.lang.Object)
	 */
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		ReservedInstancesOffering other = (ReservedInstancesOffering) obj;
		if (reservedInstancesOfferingId == null) {
			if (other.reservedInstancesOfferingId != null)
				return false;
		} else if (!reservedInstancesOfferingId
				.equals(other.reservedInstancesOfferingId))
			return false;
		return true;
	}
	
}
